<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>班级列表</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
    <link href="__PUBLIC__/css/layui.css" rel="stylesheet" type="text/css"/>
    <link href="__PUBLIC__/css/admin.css" rel="stylesheet" type="text/css"/>
    <link href="__PUBLIC__/css/public.css" rel="stylesheet" type="text/css"/>
		<style type="text/css">
			#popCon .layui-form-label{
				width: 120px;
				text-align: left;
			}
			#popCon .layui-input-block{
				margin-left: 150px;
			}
		</style>
</head>
<body>
<div class="layui-conter">
    <div class="layui-col-md12">
        <div class="navigation">
            <span>教务></span><span>班级管理></span><span>班级列表</span>
        </div>

        <div class="white-conter">
            <div class="layui-col-md12">
                <div class="layui-card">
                    <div class="title-blue">班级列表</div>
                    <div class="layui-card-body addPadding">
                        <form class="layui-form" action="" lay-filter="component-form-group">
                            <div class="layui-form-item">
                                <label class="layui-form-label">高级搜索：</label>
                                <div class="layui-input-block">
                                    <div class="layui-col-xs4">
                                        <input style="background: #dce6f0;border: none" type="text" name="title" lay-verify="title" autocomplete="off" placeholder="姓名/编号/身份证/电话/邮箱__PUBLIC__." class="layui-input">
                                    </div>
                                    <button class="layui-btn layui-btn-sm layui-btn-normal" style="margin: 0 25px;vertical-align: text-top;">搜索</button>
                                    <div class="more">更多筛选 <i class="layui-icon layui-icon-up"></i></div>
                                </div>
                            </div>
														<div class="more_show" style="display: none;">
															<div class=" layui-row" style="margin-top: 20px">
																	<div class=" layui-col-xs3">
																			<label class="layui-form-label">班级：</label>
																			<div class="layui-input-block">
																					<select name="quiz1">
																							<option value="" selected="">请选择</option>
																							<option value="1" >1</option>
																							<option value="2">2</option>
																							<option value="3">3</option>
																					</select>
																			</div>
																	</div>
																	<div class=" layui-col-xs3">
																			<label class="layui-form-label">学员状态：</label>
																			<div class="layui-input-block">
																					<select name="quiz2">
																							<option value="" selected="">请选择</option>
																							<option value="1" >1</option>
																							<option value="2">2</option>
																							<option value="3">3</option>
																					</select>
																			</div>
																	</div>
																	<div class=" layui-col-xs3">
																			<label class="layui-form-label">报名时间：</label>
																			<div class="layui-input-block">
																					<input type="text" name="signTime" id="signTime" lay-verify="date" placeholder="请选择"  class="layui-input">
																			</div>
																	</div>
																	<div class=" layui-col-xs3">
																			<label class="layui-form-label">学员生日：</label>
																			<div class="layui-input-block">
																					<input type="text" name="birthday" id="birthday" lay-verify="date" placeholder="请选择"  class="layui-input" >
																			</div>
																	</div>
															</div>
															<div class="layui-row" style="margin-top: 20px">
																	<div class="layui-col-xs3">
																			<label class="layui-form-label">性别：</label>
																			<div class="layui-input-block">
																					<select name="quiz3">
																							<option value="" selected="">请选择</option>
																							<option value="1" >男</option>
																							<option value="2">女</option>
																					</select>
																			</div>
																	</div>
																	<div class="layui-col-xs3">
																			<label class="layui-form-label">缴费状态：</label>
																			<div class="layui-input-block">
																					<select name="quiz4">
																							<option value="" selected="">请选择</option>
																							<option value="1" >1</option>
																							<option value="2">2</option>
																							<option value="3">3</option>
																					</select>
																			</div>
																	</div>
																	<div class="layui-col-xs3">
																			<label class="layui-form-label">所属地区：</label>
																			<div class="layui-input-block">
																					<input type="text" placeholder="请选择" class="layui-input" >
																			</div>
																	</div>
																	<div class="layui-col-xs3">
																			<label class="layui-form-label">手机号码：</label>
																			<div class="layui-input-block">
																					<input type="tel" name="tel" class="layui-input">
																			</div>
																	</div>
															</div>
														</div>
                            

                        </form>
                    </div>
                </div>
                <div class="layui-col-md12">
                    <div class="layui-card">
                        <div class="layui-card-body">
                            <table  class="layui-hide" id="test-table-operate" lay-filter="test-table-operate"></table>
                            <div class="layui-form layui-border-box layui-table-view" >
                                <div class="layui-table-box" style="margin-bottom: 20px">
                                    <div class="layui-table-body layui-table-main">
                                        <table cellspacing="0" cellpadding="0" border="0" class="layui-table">
                                            <thead>
                                            <tr>
                                                <th data-field="0" data-unresize="true">
                                                    <div class="layui-table-cell laytable-cell-1-0 laytable-cell-checkbox">
                                                        <input type="checkbox" name="layTableCheckbox" lay-skin="primary"
                                                               lay-filter="layTableAllChoose">
                                                        <div class="layui-unselect layui-form-checkbox" lay-skin="primary">
                                                            <i class="layui-icon layui-icon-ok"></i>
                                                        </div>
                                                    </div>
                                                </th>
                                                <th data-field="classNum">
                                                    <div class="layui-table-cell laytable-cell-1-classNum">
                                                        <span>班号</span>
                                                        </span>
                                                    </div>
                                                </th>
                                                <th data-field="className">
                                                    <div class="layui-table-cell laytable-cell-1-className" align="center">
                                                        <span>班级名称</span>
                                                    </div>
                                                </th>
                                                <th data-field="classType">
                                                    <div class="layui-table-cell laytable-cell-1-classType" align="center">
                                                        <span>相关课程</span>
                                                    </div>
                                                </th>
                                                <th data-field="startTime">
                                                    <div class="layui-table-cell laytable-cell-1-startTime" align="center">
                                                        <span>开课时间</span>
                                                    </div>
                                                </th>
                                                <th data-field="teacher">
                                                    <div class="layui-table-cell laytable-cell-1-teacher" align="center">
                                                        <span>老师</span>
                                                    </div>
                                                </th>
                                                <th data-field="director">
                                                    <div class="layui-table-cell laytable-cell-1-director" align="center">
                                                        <span>班主任</span>
                                                    </div>
                                                </th>
                                                <th data-field="campus">
                                                    <div class="layui-table-cell laytable-cell-1-className" align="center">
                                                        <span>校区</span>
                                                    </div>
                                                </th>
                                                <th data-field="zsratio">
                                                    <div class="layui-table-cell laytable-cell-1-zsratio" align="center">
                                                        <span>招生比例</span>
                                                    </div>
                                                </th>
																								<th data-field="classstate">
																										<div class="layui-table-cell laytable-cell-1-className">
																												<span>班级状态</span>
																												</span>
																										</div>
																								</th>
																								<th data-field="classstate">
																										<div class="layui-table-cell laytable-cell-1-className">
																												<span>试听课</span>
																												</span>
																										</div>
																								</th>
                                                <th data-field="operation">
                                                    <div class="layui-table-cell laytable-cell-1-operation" align="center">
                                                        <span>操作</span>
                                                    </div>
                                                </th>
                                            </tr>
                                            </thead>
                                            <tbody>
																						<foreach name="class_list" item="c" key="k">
                                            <tr data-index="{$k}" class="">
                                                <td data-field="{$k}">
                                                    <div class="layui-table-cell laytable-cell-1-0 laytable-cell-checkbox">
                                                        <input type="checkbox" name="layTableCheckbox" lay-skin="primary">
                                                        <div class="layui-unselect layui-form-checkbox" lay-skin="primary">
                                                            <i class="layui-icon layui-icon-ok"></i>
                                                        </div>
                                                    </div>
                                                </td>
                                                <td data-field="classNum" align="center">
                                                    <div class="layui-table-cell laytable-cell-1-classNum">{$c.class_num}</div>
                                                </td>
                                                <td data-field="className" align="center">
                                                    <div class="layui-table-cell laytable-cell-1-className">{$c.classname}</div>
                                                </td>
                                                <td data-field="classType" align="center">
                                                    <div class="layui-table-cell laytable-cell-1-classType">{$c.lecturename}</div>
                                                </td>
                                                <td data-field="startTime" align="center">
                                                    <div class="layui-table-cell laytable-cell-1-startTime">
                                                       {$c.start_time}
                                                    </div>
                                                </td>
                                                <td data-field="teacher" align="center">
                                                    <div class="layui-table-cell laytable-cell-1-teacher">{$c.teachername}</div>
                                                </td>
                                                <td data-field="director" align="center">
                                                    <div class="layui-table-cell laytable-cell-1-director"> {$c.headmastername}
                                                    </div>
                                                </td>
                                                <td data-field="campus" align="center">
                                                    <div class="layui-table-cell laytable-cell-1-className"> {$c.xname}  </div>
                                                </td>
                                                <td data-field="zsratio" align="center">
                                                    <div class="layui-table-cell laytable-cell-1-zsratio">
																											<div class="layui-col-md8">
																													<div class="layui-progress" style="margin-top: 13px">
																															<div class="layui-progress-bar layui-bg-blue" lay-percent="{$c.percentage}%" style="width: {$c.percentage}%;"></div>
																													</div>
																											</div>
																											<div class="layui-col-md4">
																													<span class="red">{$c.number}</span>/<span>{$c.enrollment_number}</span>
																											</div>
																										</div>
                                                </td> 
																								<td data-field="classstate" align="center">
																										<div class="layui-table-cell laytable-cell-1-className" style="color: red;">
																										<if condition="$c['class_state'] eq 1">
																											开启
																										<else/>
																											关闭
																										</if>
																										</div>
																								</td>
																								<td data-field="classstate" align="center">
																										<div class="layui-table-cell laytable-cell-1-className" style="color: red;">
																										<if condition="$c['auditions_id'] eq 1">
																											是
																										<else/>
																											否
																										</if>
																										</div>
																								</td>
                                                <td data-field="operation" align="center">
                                                    <div class="layui-table-cell laytable-cell-1-operation">
                                                       <button data-method="offset" data-type="auto" onclick="window.location.href='{:U('Customer/Classroomshow?id='.$c['id'])}'"  class="img-but look-img"></button>
                                                    </div>
                                                </td>
                                            </tr>
																						</foreach>
                                            </tbody>
                                        </table>
                                    </div>
                                </div>
                                <div class="layui-table-page">
                                    <div id="layui-table-page1">
                                        <div class="layui-box layui-laypage layui-laypage-default" id="layui-laypage-1">
                                            {$page}
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>

    </div>
</div>
</body>
<script src="__PUBLIC__/js/layui.all.js"></script>
<script>
    layui.use('laydate', function(){
        var  $ = layui.jquery,
				laydate = layui.laydate;
        //执行一个laydate实例
        laydate.render({
            elem: '#signTime'
        });
				var shows=false;
				$('.more').on('click',function(){
					if(shows == false){
						$('.more_show').show()
						$(this).find('.layui-icon').removeClass('layui-icon-up')
						$(this).find('.layui-icon').addClass('layui-icon-down')
						shows=true;
						console.log()
					}else if(shows == true){
						$('.more_show').hide()
						$(this).find('.layui-icon').removeClass('layui-icon-down')
						$(this).find('.layui-icon').addClass('layui-icon-up')
						shows=false
						console.log(12)
					}
					
				})
    });
</script>
<script>
    layui.use(["laydate","layer",'form'], function(){
        var $=layui.jquery, laydate = layui.laydate, layer = layui.layer, form=layui.form;
        //执行一个laydate实例
        laydate.render({
            elem: '#birthday'
        });
				var active = {
					bjcon:function(){
						layer.open({
							type:1,
							area: ['50%', '70%'] ,
							title:'班级详细信息',
							content:$('#popCon')
						})
					}
				}
				 $('.look-img').on('click', function(){
							var type = $(this).data('type');
							active[type] && active[type].call(this);
					});
    });
</script>
</html>